import Vue from 'vue'
import Router from 'vue-router'

import AdminRouter from './admin'
import UserRouter from './user'

Vue.use(Router)

export default new Router({
  mode: 'hash',
  linkActiveClass: 'open active',
  scrollBehavior: () => ({y: 0}), // 当转到一个新的页面时 定位到最顶端
  routes: [
    ...UserRouter,
    ...AdminRouter
  ]
})
